package com.example.patentback.service.impl;

import com.example.patentback.dao.CertificateMapper;
import com.example.patentback.entity.Certificate;
import com.example.patentback.entity.Fee;
import com.example.patentback.service.CertificateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import tk.mybatis.mapper.entity.Example;

@Service
public class CertificateServiceImpl implements CertificateService {

    @Autowired
    CertificateMapper certificateMapper;

    @Override
    public Certificate selectById(Long id) {
        Example example = new Example(Certificate.class);
        Example.Criteria criteria = example.createCriteria();
        criteria.andEqualTo("id",id);
        return certificateMapper.selectByExample(example).get(0);
    }
}
